Encoding data attributes by data stream identifiers

ABSTRACT

An example method of encoding data attributes by data stream identifiers may include: receiving a plurality of data items to be written to a storage device; identifying, among the plurality of data items, a first data item and a second data item sharing a data attribute; generate a data stream identifier comprising an encoded form of the data attribute; and transmitting, to a controller of the storage device, one or more write commands comprising the first data item and the second data item, wherein each write command further specifies the data stream identifier.

RELATED APPLICATIONS

This application is a divisional of U.S. patent application Ser. No.15/849,014 filed on Dec. 20, 2017, the entire content of which isincorporated by reference herein.

TECHNICAL FIELD

The present disclosure generally relates to storage devices, and morespecifically, relates to specifying and utilizing write streamattributes in storage write commands.

BACKGROUND

A storage device, such as a solid-state drive (SSD), may include one ormore non-volatile memory devices. The SSD may further include acontroller that may manage allocation of data on the memory devices andprovide an interface between the storage devices and the host computersystem.

BRIEF DESCRIPTION OF THE DRAWINGS

The present disclosure will be understood more fully from the detaileddescription given below and from the accompanying drawings of variousimplementations of the disclosure.

FIG. 1 schematically illustrates an example computing environmentoperating in accordance with one or more aspects of the presentdisclosure;

FIG. 2 schematically illustrates a programming model which may beimplemented by the host system in communication with the storage devicecontroller managing one or more storage devices, in accordance with oneor more aspects of the present disclosure;

FIG. 3 schematically illustrates an example structure of the writestream command, in accordance with one or more aspects of the presentdisclosure;

FIG. 4 schematically illustrates an example data placement strategyimplemented by the storage device controller operating in accordancewith one or more aspects of the present disclosure;

FIG. 5 is a flow diagram of an example method 500 of determining storageoperation parameters based on data stream attributes, in accordance withone or more aspects of the present disclosure;

FIG. 6 is a flow diagram of an example method 600 of providing datastream attributes within the data stream identifier field of streamwrite commands, in accordance with one or more aspects of the presentdisclosure;

FIG. 7 is a block diagram of an example storage device controlleroperating in accordance with one or more aspects of the presentdisclosure; and

FIG. 8 schematically illustrates a block diagram of an example computersystem in which implementations of the present disclosure may operate.

DETAILED DESCRIPTION

Aspects of the present disclosure are directed to specifying andutilizing write stream attributes in storage write commands that aretransmitted by a host system to a storage device controller. The hostsystem may group, into several data streams, the data to be written tothe storage device, such that each data stream would contain data itemsbelonging to the same group of associated data (e.g., the dataassociated with a single data structure, such as a file or a database).Thus, the data items contained by a single data stream may share one ormore attributes reflecting anticipated media usage patterns, e.g., theanticipated retention time (also referred to as the “streamtemperature”) or the workload type. In certain implementations, the datastream may be identified by a dedicated field in each write commandtransmitted by the host system to the storage device controller. Thestorage device controller may utilize the stream identifying informationin order to optimize the usage of the storage media (e.g., the negative-and (NAND) flash memory), e.g., by placing the data items of the samedata stream in a contiguous section of the storage media.

In accordance with one or more aspects of the present disclosure, one ormore bits of the stream identifier field of the write command may beutilized for specifying one or more data attributes shared by the dataitems of the data stream. Thus, each write command transmitted by thehost system to the storage device controller may not only identify thestream, but also indicate the data attributes which are shared by thedata items of the data stream. The storage device controller may utilizethe stream identifying information enhanced by the data attributes inorder to further optimize the usage of the storage media, e.g., byplacing the data items of two or more data streams sharing one or moredata attributes in the same or physically proximate sections of thestorage media and/or avoiding the placement of two or more data streamshaving substantially different data attributes in the same or physicallyproximate sections of the storage media. Such placement strategies maybe directed to distributing the programming and erasing cycles uniformlyacross the media in order to maximize the endurance of the storagemedia, as explained in more detail herein below.

Thus, aspects of the present disclosure represent significantimprovements over various common implementations of storage devices andsystems, by enhancing each write command with the data stream attributesin order to further optimize the usage of the storage media. Variousaspects of the above referenced methods and systems are described indetails herein below by way of examples, rather than by way oflimitation.

FIG. 1 schematically illustrates an example computing environment 100operating in accordance with one or more aspects of the presentdisclosure. In general, the computing environment 100 may include a hostsystem 120 that uses the storage device 110. For example, the hostsystem 120 may write data to the storage device 110 and read data fromthe storage device 110. The host system 120 may be a computing devicesuch as a desktop computer, laptop computer, network server, mobiledevice, or such computing device that includes a memory and a processingdevice. The host system 120 may include or be coupled to the storagedevice 110 so that the host system 120 may read data from or write datato the storage device 110. For example, the host system 120 may becoupled to the storage device 110 via a physical host interface.Examples of a physical host interface include, but are not limited to, aserial advanced technology attachment (SATA) interface, a peripheralcomponent interconnect express (PCIe) interface, universal serial bus(USB) interface, an NVM Express (NVMe), Fibre Channel, Serial AttachedSCSI (SAS), etc. The physical host interface may be used to transmitdata between the host system 120 and the storage device 110. In anillustrative example, the host system 120 may be represented by thecomputer system 800 of FIG. 8.

As shown in FIG. 1, the storage device 110 may include a controller 111and storage media, such as memory devices 112A to 112N. In certainimplementations, the memory devices 112A to 112N may be provided bynon-volatile memory devices, such as NAND flash memory. Each of thememory devices 112A to 112N may include one or more arrays of memorycells such as single level cells (SLCs), multi-level cells (MLCs), orquad-level cells (QLCs). Each of the memory cells may store bits of data(e.g., data blocks) used by the host system 120. Although non-volatilememory devices such as NAND flash memory are described, the memorydevices 112A to 112N may be based on any other type of memory. Forexample, the memory devices 112A to 112N may be provided by randomaccess memory (RAM), read-only memory (ROM), dynamic random accessmemory (DRAM), synchronous dynamic random access memory (SDRAM), phasechange memory (PCM), magneto random access memory (MRAM), negative- or(NOR) flash memory, and electrically erasable programmable read-onlymemory (EEPROM). Furthermore, the memory cells of the memory devices112A to 112N may be grouped as memory pages or data blocks that mayrefer to a unit of the memory device used to store data.

The controller 111 may communicate with the memory devices 112A to 112Nto perform operations including reading data from or writing data to thememory devices 112A-112N. The controller 111 may include hardware suchas one or more integrated circuits, firmware, or a combination thereof.In operation, the controller 111 may receive commands or operations fromthe host system 120 and may convert the commands or operations intoinstructions or appropriate commands to achieve the desired access tothe memory devices 112A-112N. In various illustrative examples, thecontroller 111 may be responsible for other operations such as wearleveling, garbage collection, error detection and error-correcting code(ECC), encryption, caching, and address translations between a logicalblock address and a physical block address that are associated with thememory devices 112A-112N.

In order to implement the systems and methods of the present disclosure,the controller 111 may include a data allocation functional component115 that may be employed to allocate the incoming data to particularlocations on memory devices 112A-112N. It should be noted that thecomponent designation is of a purely functional nature, i.e., thefunctions of the data allocation component may be implemented by one ormore hardware components and/or firmware modules of the controller 111,as described in more detail herein below. The storage device 110 mayinclude additional circuitry or components that are omitted from FIG. 1for clarity and conciseness.

FIG. 2 schematically illustrates a programming model which may beimplemented by the host system 120 in communication with the storagedevice controller 111 managing one or more memory devices 112A-112N, inaccordance with one or more aspects of the present disclosure. Asschematically illustrated by FIG. 2, the host system may execute one ormore applications 210A-210B. In an illustrative example, the application210A may be in communication with the file system driver 220, which maybe running in the kernel space of the host system 120 and may beemployed for processing certain system calls, such as read and writecalls initiated by one or more applications 210, including theapplication 210A, running in the user space of the host system 120. Thefile system driver 220 may be employed to translate the read, write, andother system calls issued by the application 210A into low-levelapplication programming interface (API) calls to the storage driver 230,which, in turn may communicate to the device controller 111 controllingone or more memory devices 112A-112N. The storage driver 230 may berunning in the kernel mode of the host system and may be employed toprocess API calls issued by the file system driver 220 and/or systemcalls issued by the application 210B into storage interface commands tobe processed by the storage the device controller 111 managing one ormore memory devices 112A-112N.

In an illustrative example, the storage driver 230 may implement a blockstorage model, in which the data is grouped into blocks of one or morepre-defined sizes and is addressable by a block number. The blockstorage model may implement “read” and “write” command for storing andretrieving blocks of data. In an illustrative example, the storagedriver 230 may implement a key-value storage model, in which the data isrepresented by the “value” component of a key-value pair is addressableby the “key” component of the key-value pair. The key value storagemodel may implement “put and get” commands, which are functionallysimilar to the “write” and “read” commands of the block storage model.Thus, the term “data item” as used herein may refer to a data block orto a key-value pair.

The application 210A-210B and/or the storage driver 230 executed by thehost system 120 may group, into several data streams, the data to bewritten to the memory devices 112, such that the data items belonging tothe same data stream would share one or more attributes. In anillustrative example, a data attribute may reflect the anticipatedretention time of the data stream (also referred to as the “streamtemperature”), such that a “hot” data stream would comprise short-livingdata items which are likely to be overwritten within a relatively shortperiod of time (e.g., a period of time falling below a pre-defined lowthreshold), while a “cold” data stream comprise static data items whichare not likely to be overwritten for a relatively long period of time(e.g., a period of time exceeding a pre-defined high threshold). In anillustrative example, the data stream temperature may be communicated tothe storage driver 230 by the application 210 which produces the datastream and thus is presumably aware of its anticipated retention time.The data stream temperature may be communicated to the storage driver230, e.g., via an Input/Output Control (IOCTL) system call.Alternatively, the data stream temperature may be determined by thestorage driver 230, which may buffer the incoming data to be written tothe memory devices 112A-112N, and may estimate the stream temperaturebased on the average frequency of overwrite operations requested by theapplication 210 with respect to one or more data items to be written tothe memory devices 112A-112N. The storage driver 230 may then group thebuffered data to be written to the storage device 110 into two or moredata streams, and may issue stream write commands indicating the datastream temperature to the storage device controller 111, as described inmore detail herein below.

In another illustrative example, a data attribute may reflect theworkload type of the data stream, e.g., the “log data” attributeindicating that the data represents the logging data related to one ormore databases and/or file systems or “user data” attribute indicatingthat the data represents other (not related to database or file systemlogs) types of data. The data stream workload type may be communicatedto the storage driver 230 by the application 210 which produces the datastream and thus is presumably aware of its workload type. The datastream workload type may be communicated to the storage driver 230,e.g., via an Input/Output Control (IOCTL) system call. The storagedriver may group the data labelled with the “log data” attribute intoone or more data streams, and may issue stream write commands indicatingthe workload type to the storage device controller 111, as described inmore detail herein below.

In certain implementations, the data stream may be identified by adedicated field in each write command transmitted by the host system tothe storage device controller. FIG. 3 schematically illustrates anexample structure of the write stream command, in accordance with one ormore aspects of the present disclosure. The write stream command 300 mayinclude, among other fields, the operation code field 310 specifying thecommand type (e.g., the write stream command). The write stream command300 may further include the flags field 320 specifying one or moreparameters of the command. The write stream command 300 may furtherinclude the logical block address (LBA) field 330 specifying the LBA ofthe data being stored on the storage device. The write stream command300 may further include the stream identifier field 340 represented by abit string, which may be interpreted as an unsigned integer value. Oneor more bits (such as a group of one or more most significant bits or agroup of or more least significant bits) of the stream identifier field340 may be utilized for specifying one or more data stream attributes350 shared by the data items of the data stream. In an illustrativeexample, one or more bits of the stream identifier field 340 may beutilized for specifying the data stream temperature (e.g., “0”indicating a cold stream and “1” indicating a hot stream, or “00”indicating unknown stream temperature, “01” indicating a cold stream,“10” indicating medium stream temperature, and “11” indicating a hotstream). In an illustrative example, one or more bits of the streamidentifier field 340 may be utilized for specifying the workload type ofthe data stream (e.g., “1” indicating the “log data” workload type and“0” indicating “user data” workload type). The write stream command 300may include various other fields which are omitted from FIG. 3 forclarity and conciseness.

Thus, each write command transmitted by the host system to the storagedevice controller may not only identify the stream, but also indicatethe data attributes which are shared by the data items of the datastream. The storage device controller may utilize the stream identifyinginformation enhanced by the data attributes in order to determinestorage operation parameters (such as one or more parameters definingthe data placement on the storage media) that would optimize the usageof the storage media. The storage device controller may implement one ormore wear leveling methods directed to distributing the programming anderasing cycles uniformly across the media. The wear leveling methodsimplemented by the storage device controller may involve avoidingplacing the “hot” data to the physical blocks that have experiencedrelatively heavy wear. The storage device controller may place the“cold” data and/or move the data that has not been modified for at leasta certain period of time (e.g., a period of time exceeding a certainthreshold) out of blocks that have experienced a low number ofprogramming/erasing cycles into more heavily worn blocks. This strategyfrees up the low-worn blocks for the “hot” data, while reducing theexpected wear on the heavily-worn blocks.

In an illustrative example, erasing one or more data items of one datastream may require erasing one or more data items which are storedwithin the same or physically proximate sections of the storage media.Therefore, placing the data streams having substantially differentexpected retention time within the same or physically proximate sectionsof the storage media may result in excessive number of programming anderasing cycles to be performed by the controller on the storage media.Conversely, placing the data streams having similar expected retentiontime within the same or physically proximate sections of the storagemedia may result in reducing the number of programming and erasingcycles to be performed by the controller on the storage media.Accordingly, a storage device controller operating in one or moreaspects of the present disclosure may implement a data placementstrategy which is directed to distributing the programming and erasingcycles uniformly across the media in order to maximize the endurance ofthe storage media.

FIG. 4 schematically illustrates an example data placement strategyimplemented by the storage device controller operating in accordancewith one or more aspects of the present disclosure. In an illustrativeexample, the storage device controller may place the data items of twoor more data streams sharing one or more data attributes (such as thedata stream temperature and/or data stream workload type) in the same orphysically proximate sections of the storage media. In an illustrativeexample, “section of the storage media” may be represented by a group ofone or more memory cells such as single level cells (SLCs), multi-levelcells (MLCs), or quad-level cells (QLCs) of NAND type flash memory. Inanother illustrative example, “section of the storage media” may berepresented by groups of memory units addressable by the same signal(such as a word line or a bit line).

As shown in FIG. 4, data streams 410 and 420, including data items410A-410N and 420A-420K, respectively, may share the stream temperature412 (e.g., “H” denoting “hot”). Accordingly, the storage devicecontroller may issue one or more device-level instructions to the datastorage devices in order to place the data items of the data streams 410and 420, including, for example, data items 410A, 410B, and 420A, intothe same section 450A of the storage media 400.

In another illustrative example, the storage device controller may avoidplacing two or more data streams having substantially different dataattributes (such as the data stream temperature and/or data streamworkload type) in the same or physically proximate sections of thestorage media. As shown in FIG. 4, the data stream 430 including dataitems 430A-430M may have a stream temperature 432 (e.g., “C” denoting“cold”) which is different from the stream temperature 412 shared by thedata streams 410 and 420. Accordingly, the storage device controller mayissue one or more device-level instructions to the data storage devicesin order to place the data items of the data stream 430, including, forexample, data items 430A, 430B, and 430C, into the section 450B of thestorage media 400.

FIG. 5 is a flow diagram of an example method 500 of determining storageoperation parameters based on data stream attributes, in accordance withone or more aspects of the present disclosure. The method 500 may beperformed by processing logic that may include hardware (e.g.,processing device, circuitry, dedicated logic, programmable logic,microcode, hardware of a device, integrated circuit, etc.), software(e.g., instructions run or executed on a processing device), or acombination thereof. In some embodiments, the method 500 may beperformed by the storage device controller 111 of FIG. 1.

As shown in FIG. 5, at block 510, the processing logic implementing themethod may receive, from a host system, a write command specifying adata item to be written to a memory device managed by the storage devicecontroller. The write command may further specify an identifier of adata stream to which the write command belongs. In an illustrativeexample, the identifier of the data stream is provided by an unsignedinteger value. A portion of the identifier of the data stream may encodeone or more data attributes shared by the data items of the data stream.In an illustrative example, the data attribute may include a valuereflecting an anticipated retention time of the data items of the datastream. In another illustrative example, the data attribute may includea value reflecting a workload type of the data items of the data stream,as described in more detail herein above.

At block 520, the processing logic may parse the identifier of the datastream to determine a data attribute shared by data items comprised bythe data stream. In an illustrative example, parsing the identifier ofthe data stream may involve identifying a bit string of a pre-definedsize starting from a pre-defined position within the data streamidentifier.

At block 530, the processing logic may determine, based on the dataattribute, one or more storage operation parameters (such as one or moreparameters defining the data placement on the storage media) that wouldoptimize the usage of the storage media, e.g., by uniformly distributingprogramming cycles across the storage media. In an illustrative example,a storage operation parameter may identify the section of the memorydevice to be utilized for storing the data item. In another illustrativeexample, the identified section may be located in a physical proximityof another section, which is used for storing another data stream havingthe same attribute as the data items being stored, as described in moredetail herein above.

At block 540, the processing logic may transmit, to the storage device,an instruction specifying the data item and the storage operationparameters, as described in more detail herein above.

FIG. 6 is a flow diagram of an example method 600 of providing datastream attributes within the data stream identifier field of streamwrite commands, in accordance with one or more aspects of the presentdisclosure. The method 600 may be performed by processing logic that mayinclude hardware (e.g., processing device, circuitry, dedicated logic,programmable logic, microcode, hardware of a device, integrated circuit,etc.), software (e.g., instructions run or executed on a processingdevice), or a combination thereof. In some embodiments, the method 600may be performed by the host system 120 of FIG. 1 (e.g., by the storagedriver 230 of FIG. 2).

As shown in FIG. 6, at block 610, the processing logic implementing themethod may receive a plurality of data items to be written to a storagedevice. The plurality of data items may be produced by an applicationrunning on the host system, as described in more detail herein abovewith references to FIG. 2.

At block 620, the processing logic may group the received data itemsinto one or more data streams, such that the data items contained by asingle data stream may share one or more attributes reflectinganticipated media usage patterns, e.g., the anticipated retention time(also referred to as the “stream temperature”) or the workload type. Inan illustrative example, the processing logic may identify, among theplurality of data items, two or more data items sharing one or more dataattributes. Based on the data attribute values, the processing logic mayappend the identified data items to a newly created or an existing datastream. In an illustrative example, the data attribute may include avalue reflecting an anticipated retention time of the data items of thedata stream. In another illustrative example, the data attribute mayinclude a value reflecting a workload type of the data items of the datastream, as described in more detail herein above.

At block 630, the processing logic may generate a data stream identifierwhich includes an encoded form of the data attribute. In an illustrativeexample, the data stream identifier may be provided by an unsignedinteger value, one or more bits of which may be utilized for encodingthe data attributes shared by the data items of the data stream. In anillustrative example, the bit string encoding the data attributes mayhave a pre-defined size and may start from a pre-defined position withinthe data stream identifier. In an illustrative example, the dataattribute may include a value reflecting an anticipated retention timeof the data items of the data stream. In another illustrative example,the data attribute may include a value reflecting a workload type of thedata items of the data stream, as described in more detail herein above.

At block 640, the processing logic may transmit, to a controller of thestorage device, one or more write commands specifying the data comprisedby the first data item and the second data item. Each write command mayfurther specify the data stream identifier, the reserved part of whichencodes the data attribute.

FIG. 7 is a block diagram of an example storage device controller 700,which may implement the functionality of the controller 111 of FIG. 1.As shown in FIG. 7, the controller 700 may include a host interfacecircuitry 714 to interface with a host system via a physical hostinterface 706. The host interface circuitry 714 may be employed forconverting commands received from the host system into device-levelinstructions. The host interface circuitry 714 may be in communicationwith the host-memory translation circuitry 716, which may be employedfor translating host addresses to memory device addresses. For example,the host-memory translation circuitry 716 may convert logical blockaddresses (LBAs) specified by host system read or write operations tocommands directed to non-volatile memory units identified by logicalunit numbers (LUNs) 750. The host-memory translation circuitry 716 mayinclude error detection/correction circuitry, such as exclusive or (XOR)circuitry that may calculate parity information based on informationreceived from the host interface circuitry 714.

The memory management circuitry 718 may be coupled to the host-memorytranslation circuitry 716 and the switch 720. The memory managementcircuitry 718 may control various memory management operationsincluding, but not limited to, initialization, wear leveling, garbagecollection, reclamation, and/or error detection/correction. The memorymanagement circuitry 718 may include block management circuitry 740which may be employed for retrieving data from the volatile memory 717and/or non-volatile memory identified by LUNs 750. For example, theblock management circuitry 740 may retrieve information such asidentifications of valid data blocks, erase counts, and/or other statusinformation of the LUNs 750. The memory management circuitry 718 mayfurther include data allocation component 115 that may be employed toallocate the incoming data to particular locations on logical unitsidentified by LUNs 750. It should be noted that the componentdesignation is of a purely functional nature, i.e., the functions of thedata allocation component may be implemented by one or more hardwarecomponents and/or firmware modules of the controller 700, such as theprocessor 728, which may be employed for implementing at least some ofthe above-referenced memory management operations.

The switch 720 may be coupled to the host-memory translation circuitry716, the memory management circuitry 718, the non-volatile memorycontrol circuitry 722, and/or the volatile memory control circuitry 724.The switch 720 may include and/or be coupled to a number of buffers. Forexample, the switch 720 may include internal static random access memory(SRAM) buffers (ISBs) 725. The switch may be coupled to DRAM buffers 727that are included in the volatile memory 717. In some embodiments, theswitch 720 may provide an interface between various components of thecontroller 700.

The non-volatile memory control circuitry 722 may store, in one of thebuffers (e.g., the ISBs 725 or the buffer 727), informationcorresponding to a received read command. Furthermore, the non-volatilememory control circuitry 722 may retrieve the information from one ofthe buffers and write the information to a logical unit of thenon-volatile memory identified by a LUN 750. The logical unitsidentified by LUNs 750 may be coupled to the non-volatile memory controlcircuitry 722 by a number of channels. In some embodiments, the numberof channels may be controlled collectively by the non-volatile memorycontrol circuitry 722. In some embodiments, each memory channel may becoupled to a discrete channel control circuit 748. A particular channelcontrol circuit 748 may control and be coupled to more than one memoryunit 750 by a single channel.

The non-volatile memory control circuitry 722 may include a channelrequest queue (CRQ) 747 that is coupled to each of the channel controlcircuits 748. Furthermore, each channel control circuit 748 may includea memory unit request queue (RQ) 744 that is coupled to multiple memoryunit command queues (CQs) 746. The CRQ 747 may be configured to storecommands (e.g., write requests or read requests) shared betweenchannels, the RQ 744 may be configured to store commands between thememory units 750 on a particular channel, and the CQ 746 may beconfigured to queue a current command and a next command to be executedsubsequent to the current command.

The CRQ 747 may be configured to receive a command from the switch 720and relay the command to one of the RQs 744 (e.g., the RQ 744 associatedwith the channel that is associated with the particular logical unitidentified by the LUN 750 for which the command is targeted). The RQ 744may be configured to relay a first number of commands for a particularmemory unit 750 to the CQ 746 that is associated with the particularlogical unit identified by the LUN 750 in an order that the first numberof commands were received by the RQ 744. A command pipeline may bestructured such that commands to the logical unit move in a particularorder (e.g., in the order that they were received by the RQ 744). The RQ744 may be configured to queue a command for a particular logical unitin response to the CQ 746 associated with the particular logical unitbeing full and the CRQ 747 may be configured to queue a command for aparticular RQ 744 in response to the particular RQ 744 being full.

The RQ 744 may relay a number of commands for different logical unitsidentified by LUNs 750 to the CQs 746 that are associated with thelogical units in an order according to the status of the logical units.For example, the logical unit status may be a ready/busy status. Thecommand pipeline is structured such that the commands between differentlogical units may move out of order (e.g., in an order that is differentfrom the order in which they were received by the RQ 744 according towhat is efficient for overall memory operation at the time). Forexample, the RQ 744 may be configured to relay a first one of the secondnumber of commands to a first CQ 746 before relaying a second commandfrom the second number of commands to a second CQ 746 in response to thestatus of the different logical unit associated with the second CQ 746being busy, where the first command is received later in time than thesecond command. The RQ 744 may be configured to relay the second commandto the second CQ 746 in response to the status of the logical unitassociated with the second CQ 746 being ready (e.g., subsequent torelaying the first command).

In some embodiments, the control circuits for each channel may includediscrete error detection/correction circuitry 737 (e.g., errorcorrection code (ECC) circuitry), coupled to each channel controlcircuit 748 and/or a number of error detection/correction circuits 737that can be used with more than one channel. The errordetection/correction circuitry 737 may be configured to apply errorcorrection such as Bose-Chaudhuri-Hocquenghem (BCH) error correction todetect and/or correct errors associated with information stored in thelogical unit identified by the LUN 750. The error detection/correctioncircuitry 737 may be configured to provide differing error correctionschemes for SLC, MLC, or QLC operations.

FIG. 8 illustrates an example computer system 800 within which a set ofinstructions, for causing the computer system to perform any one or moreof the methodologies discussed herein, may be executed. In anillustrative example, the computer system 800 may implement thefunctions of the host system 120 of FIG. 1. In alternativeimplementations, the computer system may be connected (e.g., networked)to other computer systems in a LAN, an intranet, an extranet, and/or theInternet. The computer system may operate in the capacity of a server ora client computer system in client-server network environment, as a peercomputer system in a peer-to-peer (or distributed) network environment,or as a server or a client computer system in a cloud computinginfrastructure or environment.

The computer system may be a personal computer (PC), a tablet PC, aset-top box (STB), a Personal Digital Assistant (PDA), a cellulartelephone, a web appliance, a server, a network router, a switch orbridge, or any computer system capable of executing a set ofinstructions (sequential or otherwise) that specify actions to be takenby that computer system. Further, while a single computer system isillustrated, the term “computer system” shall also be taken to includeany collection of computer system s that individually or jointly executea set (or multiple sets) of instructions to perform any one or more ofthe methodologies discussed herein.

The example computer system 800 includes a processing device 802, a mainmemory 804 (e.g., read-only memory (ROM), flash memory, dynamic randomaccess memory (DRAM)), a static memory 806 (e.g., flash memory, staticrandom access memory (SRAM), etc.), and a data storage device 818, whichcommunicate with each other via a bus 830. In an illustrative example,the data storage device 818 may implement the functions of the storagedevice 110 of FIG. 1.

Processing device 802 represents one or more general-purpose processingdevices such as a microprocessor, a central processing unit, or thelike. More particularly, the processing device may be complexinstruction set computing (CISC) microprocessor, reduced instruction setcomputing (RISC) microprocessor, very long instruction word (VLIW)microprocessor, or processor implementing other instruction sets, orprocessors implementing a combination of instruction sets. Processingdevice 802 may also be one or more special-purpose processing devicessuch as an application specific integrated circuit (ASIC), a fieldprogrammable gate array (FPGA), a digital signal processor (DSP),network processor, or the like. The processing device 802 is configuredto execute instructions 826 for performing the operations and stepsdiscussed herein.

The computer system 800 may further include a network interface device808 to communicate over the network 820. The computer system 800 alsomay include a video display unit 810 (e.g., a liquid crystal display(LCD) or a cathode ray tube (CRT)), an alphanumeric input device 812(e.g., a keyboard), a cursor control device 814 (e.g., a mouse), agraphics processing unit 822, a signal generation device 816 (e.g., aspeaker), graphics processing unit 822, video processing unit 828, andaudio processing unit 832.

The data storage device 818 may include computer-readable storage medium824 on which is stored one or more sets of instructions or software 826embodying any one or more of the methodologies or functions describedherein. The instructions 826 may also reside, completely or at leastpartially, within the main memory 804 and/or within the processingdevice 802 during execution thereof by the computer system 800, the mainmemory 804 and the processing device 802 also constitutingcomputer-readable storage media. The computer-readable storage medium824, data storage device 818, and/or main memory 804 may correspond tothe storage device 110 of FIG. 1.

In one implementation, the instructions 826 include instructions toimplement functionality corresponding to a data allocation component(e.g., data allocation component 115 of FIG. 1). While thecomputer-readable storage medium 824 is shown in an exampleimplementation to be a single medium, the term “computer-readablestorage medium” should be taken to include a single medium or multiplemedia (e.g., a centralized or distributed database, and/or associatedcaches and servers) that store the one or more sets of instructions. Theterm “computer-readable storage medium” shall also be taken to includeany medium that is capable of storing or encoding a set of instructionsfor execution by the computer and that cause the computer to perform anyone or more of the methodologies of the present disclosure. The term“computer-readable storage medium” shall accordingly be taken toinclude, but not be limited to, solid-state memories, optical media andmagnetic media.

Some portions of the preceding detailed descriptions have been presentedin terms of algorithms and symbolic representations of operations ondata bits within a computer memory. These algorithmic descriptions andrepresentations are the ways used by those skilled in the dataprocessing arts to most effectively convey the substance of their workto others skilled in the art. An algorithm is here, and generally,conceived to be a self-consistent sequence of operations leading to adesired result. The operations are those requiring physicalmanipulations of physical quantities. Usually, though not necessarily,these quantities take the form of electrical or magnetic signals capableof being stored, combined, compared, and otherwise manipulated. It hasproven convenient at times, principally for reasons of common usage, torefer to these signals as bits, values, elements, symbols, characters,terms, numbers, or the like.

It should be borne in mind, however, that all of these and similar termsare to be associated with the appropriate physical quantities and aremerely convenient labels applied to these quantities. Unlessspecifically stated otherwise as apparent from the above discussion, itis appreciated that throughout the description, discussions utilizingterms such as “receiving” or “determining” or “transmitting” or“reflecting” or “specifying” or “identifying” or “providing” or thelike, refer to the action and processes of a computer system, or similarelectronic computing device, that manipulates and transforms datarepresented as physical (electronic) quantities within the computersystem's registers and memories into other data similarly represented asphysical quantities within the computer system memories or registers orother such information storage devices.

The present disclosure also relates to an apparatus for performing theoperations herein. This apparatus may be specially constructed for theintended purposes, or it may comprise a general purpose computerselectively activated or reconfigured by a computer program stored inthe computer. Such a computer program may be stored in a computerreadable storage medium, such as, but not limited to, any type of diskincluding floppy disks, optical disks, CD-ROMs, and magnetic-opticaldisks, read-only memories (ROMs), random access memories (RAMs), EPROMs,EEPROMs, magnetic or optical cards, or any type of media suitable forstoring electronic instructions, each coupled to a computer system bus.

The algorithms and displays presented herein are not inherently relatedto any particular computer or other apparatus. Various general purposesystems may be used with programs in accordance with the teachingsherein, or it may prove convenient to construct a more specializedapparatus to perform the method. The structure for a variety of thesesystems will appear as set forth in the description below. In addition,the present disclosure is not described with reference to any particularprogramming language. It will be appreciated that a variety ofprogramming languages may be used to implement the teachings of thedisclosure as described herein.

The present disclosure may be provided as a computer program product, orsoftware, that may include a computer-readable medium having storedthereon instructions, which may be used to program a computer system (orother electronic devices) to perform a process according to the presentdisclosure. A computer-readable medium includes any mechanism forstoring information in a form readable by a machine (e.g., a computersystem). For example, a computer-readable (e.g., computer-readable)medium includes a read only memory (“ROM”), random access memory(“RAM”), magnetic disk storage media, optical storage media, flashmemory devices, etc.

In the foregoing specification, implementations of the disclosure havebeen described with reference to specific example implementationsthereof. It will be evident that various modifications may be madethereto without departing from the broader spirit and scope ofimplementations of the disclosure as set forth in the following claims.The specification and drawings are, accordingly, to be regarded in anillustrative sense rather than a restrictive sense.

What is claimed is:
 1. A method, comprising: receiving, by a processor,a plurality of data items to be written to a storage device;identifying, among the plurality of data items, a first data item and asecond data item sharing a data attribute; generating a bit string thatencodes the data attribute; generating a data stream identifiercomprising the bit string that encodes the data attribute; andtransmitting, to a controller of the storage device, one or more writecommands comprising the first data item and the second data item,wherein each write command further specifies the data stream identifier.2. The method of claim 1, wherein the storage device is a solid statedrive (SSD).
 3. The method of claim 1, wherein the data attributespecifies a retention time of the first data item and the second dataitem.
 4. The method of claim 3, wherein identifying the first data itemand the second data item further comprises: estimating the retentiontime of the first data item and the second data item based on an averagefrequency of requested overwrite operations.
 5. The method of claim 1,wherein the data attribute specifies a workload type of the first dataitem and the second data item.
 6. The method of claim 1, wherein the bitstring has a pre-defined size and is inserted at a pre-defined positionwithin the data stream identifier.
 7. The method of claim 1, wherein thedata attribute specifies a media usage pattern by the data itemscomprised by a data stream identified by the data stream identifier. 8.A system, comprising: a memory; a processor operatively coupled to thememory, the processor to; receive a plurality of data items to bewritten to a storage device; identify, among the plurality of dataitems, a first data item and a second data item sharing a dataattribute; generating a bit string that encodes the data attribute;generate a data stream identifier comprising the bit string that encodesthe data attribute; and transmit, to a controller of the storage device,one or more write commands comprising the first data item and the seconddata item, wherein each write command further specifies the data streamidentifier.
 9. The system of claim 8, wherein the storage device is asolid state drive (SSD).
 10. The system of claim 8, wherein the dataattribute specifies a retention time of the first data item and thesecond data item.
 11. The system of claim 10, wherein identifying thefirst data item and the second data item further comprises: estimatingthe retention time of the first data item and the second data item basedon an average frequency of requested overwrite operations.
 12. Thesystem of claim 8, wherein the data attribute specifies a workload typeof the first data item and the second data item.
 13. The system of claim8, wherein the bit string has a pre-defined size and is inserted at apre-defined position within the data stream identifier.
 14. The systemof claim 8, wherein the data attribute specifies a media usage patternby the data items comprised by a data stream identified by the datastream identifier.
 15. A non-transitory computer-readable storage mediumstoring executable instructions which, when executed by a processor,cause the processor to: receive a plurality of data items to be writtento a storage device; identify, among the plurality of data items, afirst data item and a second data item sharing a data attribute;generating a bit string that encodes the data attribute; generate a datastream identifier comprising the bit string that encodes the dataattribute; and transmit, to a controller of the storage device, one ormore write commands comprising the first data item and the second dataitem, wherein each write command further specifies the data streamidentifier.
 16. The non-transitory computer-readable storage medium ofclaim 15, wherein the storage device is a solid state drive (SSD). 17.The non-transitory computer-readable storage medium of claim 15, whereinthe data attribute specifies a retention time of the first data item andthe second data item.
 18. The non-transitory computer-readable storagemedium of claim 17, wherein identifying the first data item and thesecond data item further comprises: estimating the retention time of thefirst data item and the second data item based on an average frequencyof requested overwrite operations.
 19. The non-transitorycomputer-readable storage medium of claim 15, wherein the data attributespecifies a workload type of the first data item and the second dataitem.
 20. The non-transitory computer-readable storage medium of claim15, wherein the bit string has a pre-defined size and is inserted at apre-defined position within the data stream identifier.